using System;
using System.Collections.Generic;
using System.Text;

using SlimDX;
using SlimDX.Direct3D9;

using miciv.Rendering;

namespace miciv.Geometry
{
    public delegate IShape CreateShapeHandler();
    public delegate object UserDataOverrideHandler(string _strChannel, int _sIndex);

    public interface IShapeVertex
    {
        T GetElement<T>(string _strName) where T : struct;
    }

    public interface IShapeTopology : IEnumerable<int>
    {
        PrimitiveType PrimitiveType { get; }
        int PrimitiveSize { get; }
        int Count { get; }
    }

    public interface IShape
    {
        VertexDefinition VertexDefinition { get; set; }
        Vector3 Size { get; set; }
        int LevelOfDetail { get; set; }
        int VertexCount { get; }
        int TopologyCount { get; }
        bool Build(UserDataOverrideHandler _handler);
        IEnumerable<IShapeVertex> Vertices { get; }
        IEnumerable<IShapeTopology> Topologies { get; }
    }
}
